package entity

import (
	"github.com/lab-online/internal/shared/entity"
	"github.com/lab-online/internal/shared/valueobject"
	"github.com/lab-online/pkg/auth"
)

type Class struct {
	entity.Base
	Name        string
	Description string
	CourseID    uint
	Teacher     valueobject.UserVO
	Students    []valueobject.UserVO
}

type ClassEntity interface {
	GetID() uint
	GetName() string
	GetDescription() string
	GetCourseID() uint
	GetTeacher() string
	GetTeacherVO() valueobject.UserVO
	GetStudents() []string
	GetStudentVOs() []valueobject.UserVO

	UpdateEntity(...ClassOption)
	CanHandleClass(authEntity auth.AuthEntity, readOnly bool) bool
	ContainsStudent(string) bool
	ApplyStudentPatch(...valueobject.PatchVO)
}
